package com.example.dubbo.provider.service.impl;

import com.example.dubbo.service.HelloService;
import lombok.SneakyThrows;
import org.apache.dubbo.config.annotation.DubboService;
import org.springframework.stereotype.Component;

import java.util.concurrent.TimeUnit;

/**
 * @author zxs
 * @since 2019/11/20
 */
@DubboService
@Component
public class HelloServiceImpl implements HelloService {

    @Override
    @SneakyThrows
    public String hello(String target) {
        TimeUnit.SECONDS.sleep(1);
        return "call version 0.2 ";
    }
}
